import request from '@/utils/request'


export function createYzWallet(data) {
  return request({
    url: '/api/YzWallet/save',
    method: 'post',
    data
  })
}

export function delYzWallet(id) {
  return request({
    url: '/api/YzWallet/del/'+id,
    method: 'post'
  })
}


export function batchDel(data) {
  return request({
    url: '/api/YzWallet/batch/del',
    method: 'post',
    data
  })
}

export function editYzWallet(data) {
  return request({
    url: '/api/YzWallet/update',
    method: 'post',
    data
  })
}



export function getInfo(id) {
  return request({
    url: '/api/YzWallet/get/'+id,
    method: 'get',
    params: { id }
  })
}


export function getPageYzWallet(query) {
  return request({
    url: '/api/YzWallet/getPage',
    method: 'post',
    data: query
  })
}

export function getListYzWallet(query) {
  return request({
    url: '/api/YzWallet/getList',
    method: 'post',
    data: query
  })
}

// 退款审核
export function approvalRefundAudit(query) {
  return request({
    url: '/api/YzWallet/refundAudit',
    method: 'post',
    data: query
  })
}
// 充值
export function rechargeWallet(query) {
  return request({
    url: '/api/yzWallet/recharge',
    method: 'post',
    data: query
  })
}
// 退款
export function fetchRefund(query) {
  return request({
    url: '/api/YzWallet/refund',
    method: 'post',
    data: query
  })
}
// 提现
export function fetchMerchant(query) {
  return request({
    url: '/api/yzWallet/merchant/transfer',
    method: 'post',
    data: query
  })
}